home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Compute! Gazette 1984 September
/
1984-09.d64
/
mystery manor_vi
(
.txt
)
< prev
next >
Wrap
Commodore BASIC
|
2022-09-20
|
3KB
|
91 lines
5 poke36879,29:print"[147][144][205]ystery at"chr$(14):printtab(7)"[205]arple"
10 printtab(12)"[205]anor"
100 d$="nesw":t$="ec@bdanmkhga@fb@f@a@@@edci@@@jich@@g@@@h@@cl@km@lb@nbm@@"
105 deffnr(x)=int(rnd(1)*x)+1:j=rnd(-ti):dimp%(39)
110 forj=0to21:p%(j)=fnr(13)+1:next:j=fnr(10)-1
115 p%(25)=j+1:p%(24)=p%(j):p%(j)=0
120 i=fnr(10)-1:ifi=jthen120
125 p%(22)=i+1:p%(i)=0:j=fnr(12):p%(23)=j:p%(9+j)=0
130 forj=0to21:ifrnd(1)<.8thenp%(j)=-p%(j)
135 next:print"[208][204][193][217][197][210][211] (1-6)?"
140 geta$:j=val(a$):ifj<1orj>6then140
145 p%(38)=j:fori=1toj:p%(25+i)=1:next:q=1
200 print"[147][144]player #"q:printchr$(142)"---press return"
205 geta$:ifa$<>chr$(13)then205
210 r=p%(q+25):print"you are in":print"the ";:x=r+22:gosub3000
215 print"leave? [y/n]"
220 geta$:ifa$="n"then275
225 ifa$<>"y"then220
230 c$=mid$(t$,4*r-3,4):print"exits are to the:"
235 fori=1to4:x=i+36:ifmid$(c$,i,1)>"@"thengosub3000
240 next:print"type nse[146] or w":i=0
245 geta$:ifa$<"e"then245
250 forj=1to4:ifmid$(d$,j,1)=a$theni=j
255 next:ifi=0then245
260 x=36+i:print"moving ";:gosub3000:a$=mid$(c$,i,1)
265 i=asc(a$)-64:ifi<1thenprint"no door":print"no move":gosub4050:goto275
270 r=i:p%(q+25)=i
275 gosub4050
276 print"[147]you are in":print"the ";:x=r+22:gosub3000
280 print"you have";:x=p%(31+q)+1:ifx=1thenprint" no item":goto290
285 print" the ";:gosub3000
290 p=0:print"you see:":fori=0to21
295 ifp%(i)=rthenx=i+1:print"the ";:gosub3000:p=1
300 next:ifp%(24)=rthengosub3100:p=1
305 forj=1to6:ifj<>qandp%(j+25)=rthenprint"player"j:p=1
310 next:ifp=0thenprint"nothing!"
315 input"press return";a$
400 print"[147][144] options: "
401 print"1 accuse":print"2 drop":print"3 take":print"4 search"
405 print"5 pilfer":print"6 no action":print"[144]choose now!"
415 geta$:i=val(a$):onigoto600,700,750,800,850,500
420 goto415
500 input"press return";a$
505 q=q+1:ifq>p%(38)thenq=1
510 ifp%(q+25)=0then505
515 goto200
600 p=1:w=0:z=10:gosub3200:input"victim";j:ifj<>p%(25)thenp=0
605 gosub3200:input"murderer";j:ifj<>p%(22)thenp=0
610 w=10:z=12:gosub3200:input"weapon";j:ifj<>p%(23)thenp=0
615 w=22:z=14:gosub3200:input"scene";j:ifj<>abs(p%(24))thenp=0
650 ifpthenprint"[147]that's right!":print"you win!":goto670
655 print"[147]wrong solution!":print"you lose!"
660 p%(25+q)=0:p%(39)=p%(39)+1:gosub3300:ifp%(39)<p%(38)then500
665 print"all players have lost!"
670 print"the solution:":print"[144]the ";:x=p%(22):gosub3000
673 print"killed the ";:x=p%(25):gosub3000
675 print"in the ";:x=22+abs(p%(24)):gosub3000
678 print"with the ";:x=p%(23)+10:gosub3000:end
700 gosub3300:ifx=0thenprint"drop no item":goto500
705 print"you drop the ";:gosub3000:goto500
750 p=1:print"available:":fori=10to21:ifp%(i)=rthengosub3400
760 next:ifp=1thenprint"no items":goto500
765 input"choose";z:ifz<0orz>=pthen765
770 ifz=0thenprint"take nothing":goto500
775 gosub3300:ifx>0thenprint"drop the ";:gosub3000
780 i=peek(900+z):p%(i)=100+q:p%(q+31)=i:x=i+1:print"you take the ";:gosub3000:goto500
800 p=0:print"you find:":fori=0to21:ifp%(i)<>-rorrnd(1)>.6then810
805 p=1:print"the ";:x=i+1:gosub3000:p%(i)=r
810 next:ifp%(24)=-randrnd(1)<.6thenp=1:gosub3100:p%(24)=r
820 ifp=0thenprint"--nothing"
825 goto500
850 p=0:print"now here:":fori=1to6:ifp%(25+i)=randi<>qthenprint"player #"i:p=1
860 next:ifp=0thenprint"nobody!":goto500
865 input"steal from whom";w:ifw<0orw>p%(38)then865
870 ifp%(25+w)<>rthenprint"not here!":goto865
875 gosub3300:ifx>0thenprint"drop the ";:gosub3000
880 p=p%(w+31):ifp=0thenprint"nothing taken":goto500
885 p%(q+31)=p:p%(w+31)=0:p%(p)=100+q:x=p+1:print"you take the ";:gosub3000:goto500
3000 forj=1tox:readx$:next:printx$:restore:return
3100 x=p%(25):print"the body of":print"the ";:gosub3000:return
3200 print"[147][144]":fori=1toz:x=i+w:printitab(4)": the ";:gosub3000:next:return
3300 i=p%(q+31):x=0:ifi=0thenreturn
3305 p%(i)=r:p%(q+31)=0:x=i+1:return
3400 printptab(4)":the ";:x=i+1:gosub3000:poke900+p,i:p=p+1:return
4000 datacook,butler,gardener,doctor,duke,duchess,nanny,"film star"
4005 datasenator,judge,knife,rope,poison,mace,pistol,sword,"ice pick"
4010 databomb,razor,lamp,club,shovel,foyer,corridor,hall,pantry,"dining room"
4015 datakitchen,study,bedroom,bathroom,closet,greenhouse,garden,pool
4020 datagarage,north,east,south,west
4050 fori=1to1200:next:return